package cn.lin.task.model;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

@Entity
@Table(name="t_admin")
public class Admin {
	private int aid;
	private String adminname;
	private String password;
	
	
	
	public Admin() {
		
	}
	
	
	
	public Admin(String adminname, String password) {
		this.adminname = adminname;
		this.password = password;
	}


	@Id 
	@GeneratedValue(generator = "persistenceGenerator")    
	@GenericGenerator(name = "persistenceGenerator", strategy = "increment")
	public int getAid() {
		return aid;
	}
	public void setAid(int aid) {
		this.aid = aid;
	}
	public String getAdminname() {
		return adminname;
	}
	public void setAdminname(String adminname) {
		this.adminname = adminname;
	}
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}



	@Override
	public String toString() {
		return "Admin [aid=" + aid + ", adminname=" + adminname + ", password=" + password + "]";
	}
	
	
	
}
